<layout name="layout" />

<div class="main-div">
    <form name="main_form" method="POST" action="__SELF__" enctype="multipart/form-data" >
    	<input type="hidden" name="id" value="<?php echo $data['id']; ?>" />
        <table cellspacing="1" cellpadding="3" width="100%">
            <tr>
                <td class="label">角色名称：</td>
                <td>
                    <input  type="text" name="role_name" value="<?php echo $data['role_name']; ?>" />
                </td>
            </tr>
                 <tr>
                <td class="label">权限列表：</td>
                <td>
                   <?php foreach($parentData as $k =>$v):
                      if(strpos(','.$priroleData.',',','.$v['id'].',')!==false)
                    				$check = 'checked="checked"';
                    			else 
                    				$check = ''
                   ?>
                   <p> <?php echo str_repeat('-', 8*$v['level']); ?> <input type="checkbox" name="priids[]" <?php echo $check;?> value="<?php echo $v['id']?>"> <?php echo $v['pri_name']?></p>
                   <?php endforeach;?>
                </td>
            </tr>
            <tr>
                <td colspan="99" align="center">
                    <input type="submit" class="button" value=" 确定 " />
                    <input type="reset" class="button" value=" 重置 " />
                </td>
            </tr>
        </table>
    </form>
</div>


<script>
</script>